package com.lcf.system.controller;

import com.lcf.system.dto.sms.SmsDTO;
import com.lcf.system.service.SmsService;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.annotation.Resource;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 短信
 *
 * @author lcf
 */
@Tag(name = "短信")
@RequestMapping("/sms")
@RestController
public class SmsController {
    @Resource
    private SmsService smsService;

    /**
     * 发送绑定手机验证码
     */
    @Operation(summary = "发送绑定手机验证码")
    @PostMapping("sendBindPhoneCode")
    public void sendBindPhoneCode(@Validated SmsDTO phone) {
        smsService.sendBindPhoneCode(phone);
    }
}
